'use client'
import React from 'react'
import { Button } from '@arco-design/web-react'
import { IconSend } from '@arco-design/web-react/icon'
import UploadIcon from '../base/upload-icon'

type SendButtonProps = {
  onClick: () => void
  disabled?: boolean
  onFileUpload?: (file: File) => void
}

const SendButton: React.FC<SendButtonProps> = ({
  onClick,
  disabled = false,
  onFileUpload,
}) => {
  return (
    <div className="flex items-center space-x-2">
      {onFileUpload && (
        <UploadIcon
          onFileUpload={onFileUpload}
          size="small"
          className="mr-1"
        />
      )}
      <Button
        type="primary"
        icon={<IconSend />}
        onClick={onClick}
        disabled={disabled}
      >
                发送
      </Button>
    </div>
  )
}

export default SendButton
